home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 2000 July: Mac OS SDK / Dev.CD Jul 00 SDK2.toast / Development Kits / Cross Platform / QuickTime 4.1.2 Windows SDK / CIncludes / CMAcceleration.h < prev    next >
Encoding:
C/C++ Source or Header  |  2000-04-12  |  4.1 KB  |  141 lines  |  [TEXT/R*ch]

  1. /*
  2.      File:        CMAcceleration.h
  3.  
  4.      Contains:    ColorSync Acceleration Component API
  5.  
  6.      Version:    Technology:    ColorSync 2.0
  7.                  Release:    QuickTime 4.1
  8.  
  9.      Copyright:    (c) 1995-1999 by Apple Computer, Inc., all rights reserved.
  10.  
  11.      Bugs?:        For bug reports, consult the following page on
  12.                  the World Wide Web:
  13.  
  14.                      http://developer.apple.com/bugreporter/
  15.  
  16. */
  17. #ifndef __CMACCELERATION__
  18. #define __CMACCELERATION__
  19.  
  20. #ifndef __COMPONENTS__
  21.     #include <Components.h>
  22. #endif
  23.  
  24. #ifndef __CMAPPLICATION__
  25.     #include <CMApplication.h>
  26. #endif
  27.  
  28.  
  29.  
  30.  
  31. #if PRAGMA_ONCE
  32. #pragma once
  33. #endif
  34.  
  35. #ifdef __cplusplus
  36. extern "C" {
  37. #endif
  38.  
  39. #if PRAGMA_IMPORT
  40. #pragma import on
  41. #endif
  42.  
  43. #if PRAGMA_STRUCT_ALIGN
  44.     #pragma options align=mac68k
  45. #elif PRAGMA_STRUCT_PACKPUSH
  46.     #pragma pack(push, 2)
  47. #elif PRAGMA_STRUCT_PACK
  48.     #pragma pack(2)
  49. #endif
  50.  
  51. /* -------------------------------------- version info */
  52. enum {
  53.     cmAccelerationInterfaceVersion = 1
  54. };
  55.  
  56. /* -------------------------------------- Component Type */
  57. enum {
  58.     cmAccelerationComponentType    = FOUR_CHAR_CODE('csac')
  59. };
  60.  
  61. /* -------------------------------------- Required Component function selectors */
  62. enum {
  63.     cmLoadTables                = 0,
  64.     cmCalculateData                = 1
  65. };
  66.  
  67. /* -------------------------------------- table data for acceleration component */
  68.  
  69. struct CMAccelerationTableData {
  70.     long                             inputLutEntryCount;            /* count of entries for input lut for one dimension*/
  71.     long                             inputLutWordSize;            /* count of bits of each entry ( e.g. 16 for WORD )*/
  72.     Handle                             inputLut;                    /* handle to input lut*/
  73.     long                             outputLutEntryCount;        /* count of entries for output lut for one dimension    */
  74.     long                             outputLutWordSize;            /* count of bits of each entry ( e.g. 8 for BYTE )*/
  75.     Handle                             outputLut;                    /* handle to output lut*/
  76.     long                             colorLutInDim;                /* input dimension  ( e.g. 3 for LAB ; 4 for CMYK )*/
  77.     long                             colorLutOutDim;                /* output dimension ( e.g. 3 for LAB ; 4 for CMYK )*/
  78.     long                             colorLutGridPoints;            /* count of gridpoints for color lut ( for one Dimension )    */
  79.     long                             colorLutWordSize;            /* count of bits of each entry ( e.g. 8 for BYTE )*/
  80.     Handle                             colorLut;                    /* handle to color lut*/
  81.     CMBitmapColorSpace                 inputColorSpace;            /* packing info for input*/
  82.     CMBitmapColorSpace                 outputColorSpace;            /* packing info for output*/
  83.     void *                            userData;
  84.     unsigned long                     reserved1;
  85.     unsigned long                     reserved2;
  86.     unsigned long                     reserved3;
  87.     unsigned long                     reserved4;
  88.     unsigned long                     reserved5;
  89. };
  90. typedef struct CMAccelerationTableData    CMAccelerationTableData;
  91. typedef CMAccelerationTableData *        CMAccelerationTableDataPtr;
  92. typedef CMAccelerationTableDataPtr *    CMAccelerationTableDataHdl;
  93. /* -------------------------------------- calc data for acceleration component */
  94.  
  95. struct CMAccelerationCalcData {
  96.     long                             pixelCount;                    /* count of input pixels*/
  97.     Ptr                             inputData;                    /* input array*/
  98.     Ptr                             outputData;                    /* output array*/
  99.     unsigned long                     reserved1;
  100.     unsigned long                     reserved2;
  101. };
  102. typedef struct CMAccelerationCalcData    CMAccelerationCalcData;
  103. typedef CMAccelerationCalcData *        CMAccelerationCalcDataPtr;
  104. typedef CMAccelerationCalcDataPtr *        CMAccelerationCalcDataHdl;
  105. /*
  106.    ------------------------------------------------------------------------------------------------ 
  107.                   A c c e l e r a t i o n   C o m p o n e n t   I n t e r f a c e s
  108.    ------------------------------------------------------------------------------------------------ 
  109. */
  110. EXTERN_API( CMError )
  111. CMAccelerationLoadTables        (ComponentInstance         CMSession,
  112.                                  CMAccelerationTableDataPtr  tableData)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0000, 0x7000, 0xA82A);
  113.  
  114.  
  115. EXTERN_API( CMError )
  116. CMAccelerationCalculateData        (ComponentInstance         CMSession,
  117.                                  CMAccelerationCalcDataPtr  calcData)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0001, 0x7000, 0xA82A);
  118.  
  119.  
  120.  
  121. #if PRAGMA_STRUCT_ALIGN
  122.     #pragma options align=reset
  123. #elif PRAGMA_STRUCT_PACKPUSH
  124.     #pragma pack(pop)
  125. #elif PRAGMA_STRUCT_PACK
  126.     #pragma pack()
  127. #endif
  128.  
  129. #ifdef PRAGMA_IMPORT_OFF
  130. #pragma import off
  131. #elif PRAGMA_IMPORT
  132. #pragma import reset
  133. #endif
  134.  
  135. #ifdef __cplusplus
  136. }
  137. #endif
  138.  
  139. #endif /* __CMACCELERATION__ */
  140.  
  141.